﻿/****************************************************************
 * Copyright (c) 2010-2013 Besture All Rights Reserved.
 * 
 * File Name:		QueryDal 
 * 
 * Created:		2013-8-28 19:01:29
 * Original Author:	nitao 
 * 
 * ------------------------------------------------------------
 * MODIFICATION HISTORY
 * ------------------------------------------------------------
 * When			Who		Why
 * ------------------------------------------------------------
 * 
 *
 ****************************************************************/

using System;
using System.Data;
using System.Data.Common;
using Besture.Common;

namespace Besture.Dal
{
    public class QueryDal : BaseDataAccess
    {
        /// <summary>
        /// 获取全部数据
        /// </summary>
        /// <returns></returns>
        public DataTable GetTable(string sql)
        {
            try
            {
                DbCommand ldcDBCommand = base.GetCommand(sql);
                DataTable dt = base.GetDataSet(ldcDBCommand).Tables[0];
                return dt;
            }
            catch (Exception)
            {
                throw;
            }
        }
    }
}
